Skip to content

[Flagship] add wrangler flagship documentation#31825

Open
akshitsinha wants to merge 2 commits into
cloudflare:productionfrom
akshitsinha:asinha/wrangler-flagship
Open

[Flagship] add wrangler flagship documentation#31825
akshitsinha wants to merge 2 commits into
cloudflare:productionfrom
akshitsinha:asinha/wrangler-flagship

Conversation

@akshitsinha

@akshitsinha akshitsinha commented Jul 1, 2026

Copy link
Copy Markdown
Member

Summary

Adds documentation for the new wrangler flagship CLI command group, which manages Flagship apps and feature flags from the command line.

This change adds:

  • A new reference page, flagship/reference/wrangler-commands, covering authentication, binding a Flagship app to a Worker, creating and inspecting apps and flags, targeting rules (including the compact rule syntax and --rule-json), rollouts and traffic splits, enabling and disabling flags, evaluating flags, changelog history, and scripting with --json output.
  • A new Wrangler command reference page at workers/wrangler/commands/flagship, consistent with how other Wrangler command groups are documented, that links to the fuller Flagship reference guide for complete workflows.
  • A link to the new reference page from the existing Flagship "Get started" guide.

Documentation checklist

@github-actions github-actions Bot added the product:workers Related to Workers product label Jul 1, 2026
@cloudflare-docs-bot

cloudflare-docs-bot Bot commented Jul 1, 2026

Copy link
Copy Markdown
Contributor

Review

⚠️ 8 warnings, 💡 2 suggestions found in commit 651d1a1.

Code Review

This code review is in beta and may not always be helpful — use your judgment.

Warnings (6)
File Issue
catalog-models/anthropic-claude-sonnet-4.6.json line 562 Truncated example output — The Web Search example's output.text ends mid-sentence ("...AI Agent Verification in Bot Management\*\* \u2014 ") and omits the rest of the generated summary. The complete response exists in raw_response.content across multiple subsequent text blocks, but output.text only captures the first fragment. The other examples have complete output.text values matching their raw_response. Fix: Reconstruct output.text from the full set of raw_response.content text blocks (and omit citations) so the example summary is complete and consistent with the other examples.
catalog-models/google-gemini-2.5-pro.json line 540 Incomplete numeric range constraint — The numeric property following frequency_penalty (likely presence_penalty) defines "maximum": 2 but omits a "minimum" bound, unlike the preceding frequency_penalty which correctly spans -2 to 2. Fix: Add "minimum": -2 to this property so its accepted range matches OpenAI's presence_penalty semantics and mirrors the frequency_penalty constraint.
catalog-models/openai-gpt-4.1-mini.json PR scope mismatch — PR #31825 is titled "Add wrangler flagship command documentation", but the changed file is src/content/catalog-models/openai-gpt-4.1-mini.json, an OpenAI model catalog data file unrelated to wrangler. Fix: Confirm that updating this model catalog file is intentional. If it is unrelated to the wrangler documentation change, move it to a separate PR or update the PR title/description to include it.
catalog-models/openai-gpt-4.1-nano.json Unrelated file change — PR #31825 is titled 'Add wrangler flagship command documentation', but the only changed file reviewed is an OpenAI GPT-4.1 nano model catalog JSON (schema additions for Responses and Chat Completions). A wrangler-docs PR should not need to modify an AI model catalog. Fix: Confirm whether this file was intended for this PR. If it is an accidental inclusion, remove it from the branch so it is not merged with the wrangler documentation changes.
flagship/reference/wrangler-commands.mdx line 13 Inaccurate command signature description — Line 13 states every wrangler flagship flags command takes the app ID followed by the flag key, but the documented wrangler flagship flags list <APP_ID> (line 263) takes only an app ID with no flag key, so the claim is incorrect and could mislead users into passing an extra argument. Fix: Clarify that most wrangler flagship flags subcommands require a flag key after the app ID, while list-style commands such as flags list take only the app ID.
workers/wrangler/commands/flagship.mdx line 99 Inaccurate --force requirement for rollout/split — The sentence states rollout and split require --force when they would replace existing targeting rules, but the Flagship Wrangler commands reference says only rules with real conditions trigger a confirmation prompt; rules created by a previous rollout/split (no conditions) are replaced without a prompt. Fix: Clarify that --force is required only when rollout/split would overwrite existing targeting rules that have conditions.
Suggestions (1)
File Issue
catalog-models/google-gemini-2.5-pro.json line 640 Duplicate oneOf title — The added schema branches set "title": "Generate Content" at both line 474 and line 640, and "title": "Chat Completions" at lines 606 and 764, making the oneOf branches indistinguishable by title. Fix: Use unique titles for each oneOf branch, or verify that the second pair is intended for schema.output rather than another schema.input alternative.

Conventions

Checks PR title, description, and redirect checklist.

No convention issues found.

Style Guide Review

Warnings (2)
File Issue
flagship/reference/wrangler-commands.mdx line 40 WranglerConfig input must be TOML<WranglerConfig> wraps a ```jsonc block for the Flagship binding snippet. Fix: Provide the Wrangler configuration as ```toml inside <WranglerConfig>; JSONC output is auto-generated.
workers/wrangler/commands/flagship.mdx line 33 No contractions — Line uses the contraction don't in body prose Fix: Change don't to do not
Suggestions (1)
File Issue
changelog/flagship/2026-07-06-wrangler-commands.mdx line 57 Passive voice — Line uses passive voice: "These commands can also be used from ..." Fix: Rewrite in active voice, for example: "You can also use these commands from CI/CD pipelines, scripts, and AI agents to inspect Flagship state, update flag behavior, or roll back changes through Wrangler."

Redirects

No missing redirect entries found.

Commands

Only codeowners can run commands. Post a comment with the command to trigger it.

Command Description
/review Runs a review now. Incremental if a prior review exists, full if not.
/full-review Re-reviews the entire PR diff from scratch, ignoring incremental history. Useful after a rebase, when you want a fresh review, or if the bot gets out of sync and reports issues that no longer exist.
/ignore-review-limit Permanently lifts the 2-review automatic limit for this PR. Future pushes will trigger reviews as normal.
/disable-auto-review Stops automatic reviews from triggering on future pushes to this PR. Codeowners can still run /review or /full-review manually.

@irvinebroque irvinebroque left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Changelog?

@MattieTK for review

@akshitsinha akshitsinha force-pushed the asinha/wrangler-flagship branch from 781008b to 9e4e958 Compare July 3, 2026 07:17
@akshitsinha akshitsinha marked this pull request as ready for review July 3, 2026 07:28
@akshitsinha akshitsinha requested review from a team as code owners July 3, 2026 07:28
@akshitsinha akshitsinha changed the title Add wrangler flagship command documentation [Flagship] add wrangler flagship documentation Jul 3, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

8 participants